Time synchronization of signal transmission intervals for simulating a machine in industrial automation

ABSTRACT

Systems, methods, and software to facilitate simulating machines used in industrial automation are disclosed herein. In at least one implementation, an API is utilized to establish at least a communication link between a simulation model created in a simulation application and an industrial controller system outside of the simulation model, wherein the simulation model comprises definitions for a virtual representation of at least a portion of a machine used in an industrial automation environment. Data is then exchanged between the industrial controller system and the simulation model over the communication link.

RELATED APPLICATIONS

This application hereby claims the benefit of, and priority to, U.S.Provisional Patent Application No. 61/901,956, entitled “INTEGRATINGCONTROLLERS WITH SIMULATIONS”, filed Nov. 8, 2013, and which is herebyincorporated by reference in its entirety for all purposes.

TECHNICAL BACKGROUND

Simulation of industrial equipment can be essential in designing,prototyping, and demonstrating the different design options toengineers, customers, and other interested parties. Such simulations canbe utilized to emulate virtualized operation of their correspondingphysical devices over time, and may be further used in providing visualrepresentations of the various simulated devices. In some examples,simulation and modeling applications may be used to define parametersfor simulated mechanical components. These parameters ensure that theemulated equipment performs in the same manner during a simulation ascan be expected for their real-world counterparts.

In addition to the physical industrial equipment that provides themechanical functionality to perform various industrial operations,controller systems are also essential components of an industrialautomation environment. Industrial controller systems are typicallyutilized to provide control instructions to physical machines toaccomplish various tasks in an industrial plant, such as productmanufacturing, materials handling, batch processing, supervisorycontrol, and other industrial functions. As a result, by combiningindustrial machinery with the proper controller, an industrial systemcan be created that is capable of performing various operations.

Overview

Systems, methods, and software to facilitate simulating machines used inindustrial automation are disclosed herein. In at least oneimplementation, an API is utilized to apply timestamps to data exchangedbetween a simulation model created in a simulation application and anindustrial controller system external to the simulation model. Thetimestamps are then processed to synchronize the simulation model andthe industrial controller system.

This Overview is provided to introduce a selection of concepts in asimplified form that are further described below in the TechnicalDisclosure. It should be understood that this Overview is not intendedto identify key features or essential features of the claimed subjectmatter, nor is it intended to be used to limit the scope of the claimedsubject matter.

BRIEF DESCRIPTION OF THE DRAWINGS

Many aspects of the disclosure can be better understood with referenceto the following drawings. While several implementations are describedin connection with these drawings, the disclosure is not limited to theimplementations disclosed herein. On the contrary, the intent is tocover all alternatives, modifications, and equivalents.

FIG. 1A is a block diagram that illustrates an overview of synchronizingmultiple controllers with simulated industrial devices.

FIG. 1B is a block diagram that illustrates a computing system that maybe used to facilitate simulating machines used in industrial automation.

FIG. 2 is a flow diagram that illustrates an operation of a computingsystem in an exemplary implementation.

FIG. 3 is a block diagram that illustrates an overview of implementingcontrollers with simulated industrial devices.

FIG. 4 is a block diagram that illustrates an operational scenarioinvolving a computing system in an exemplary implementation.

FIG. 5 is a block diagram that illustrates an operational scenario forsynchronizing a controller and a simulation in an exemplaryimplementation.

FIG. 6 is a controller synchronization chart that illustrates anexemplary technique of synchronizing multiple controllers.

FIG. 7 is a block diagram that illustrates an operational scenarioinvolving a computing system in an exemplary implementation.

FIG. 8 is a block diagram that illustrates a computing system in anexemplary implementation.

DETAILED DESCRIPTION

The following description and associated drawings teach the best mode ofthe invention. For the purpose of teaching inventive principles, someconventional aspects of the best mode may be simplified or omitted. Thefollowing claims specify the scope of the invention. Some aspects of thebest mode may not fall within the scope of the invention as specified bythe claims. Thus, those skilled in the art will appreciate variationsfrom the best mode that fall within the scope of the invention. Thoseskilled in the art will appreciate that the features described below canbe combined in various ways to form multiple variations of theinvention. As a result, the invention is not limited to the specificexamples described below, but only by claims and their equivalents.

Industrial automation environments, such as automobile manufacturingfactories, food processing plants, oil drilling operations,microprocessor fabrication facilities, and other types of industrialenterprises, typically employ several machines and other equipment tocarry out their business operations. For example, an industrialautomation enterprise could employ machines comprising sensors, drives,pumps, filters, drills, motors, robots, mills, printers, carousels,fabrication machinery, or any other industrial automation equipment.During the design, prototyping, and testing phases of productdevelopment, these machines and other devices used in industrialautomation may be simulated using computing systems to provide virtualrepresentations to engineers and customers of the end product. Thesesimulations typically include physical attributes, parameters, and otheraspects of the machine being simulated to ensure a proper emulation isfurnished by the computing system. In some examples, a user may desireto have control over a simulated device to further illustrate thefunctionality and operation of the device as can be expected whenphysically implemented. As a result, the user may prefer to attach oneor more real or emulated controllers to the simulated device todemonstrate and test the different controllable operations of thedevice.

FIG. 1A is a block diagram that illustrates an overview 101 ofsynchronizing multiple controllers 151-152 with simulated industrialdevices. FIG. 1A shows a functional mock-up interface emulationsimulation interface (FMI-ESI), controllers 151 and 161, controller-sidefunctional mock-up unit (FMU) 152 and FMU 162, co-simulation master 150,and simulation FMU 155.

Controllers 151 and 161 typically each comprise an industrialcontroller, which could include automation controllers, programmablelogic controllers (PLCs), or any other controllers used in automationcontrol. Controllers 151 and 161 could comprise one or more physicaland/or emulated controllers implemented in software—includingcombinations thereof. In this example, each controller 151 and 161 hasan associated controller-side FMU 152 and 162, respectively. Eachcontroller-side FMU 152 and 162 includes an application programminginterface (API) that may be used to read and write tags and synchronizetime between the controllers 151 and 162 and their respectivecontroller-side FMUs 152 and 162.

Simulation FMU 155 comprises definitions for a virtual representation ofat least a portion of a machine used in an industrial automationenvironment. Simulation FMU 155 is typically created, at least in part,using a simulation application that complies with the FMI standard, sothat FMI may be used to wrap the simulation module inside of an FMU. Forexample, the simulation application could comprise a third-partysimulation framework tool, such as MATLAB® Simulink™, although thesimulation application could comprise any other suitable simulationapplication or combination of applications in some implementations. EachFMU provides an interface for exchanging data with other FMUs.

In operation, a tag server within the FMI-ESI provides distributedcommunication connectivity services for connecting the communicatingparts on the controller side. The communication between controller-sideFMUs 152 and 162 and the simulation FMU 155 is coordinated by theco-simulation master 150, which also complies with FMI. The clocksynchronization is typically performed in two phases. First, theco-simulation master 150 coordinates global time among all the FMUs 152,162, and 155, which involves sending a clock pulse to each FMU at eachtime step interval in order to inject the global time into each FMU.Second, the tag server service within the FMI-ESI coordinatescontroller-side FMU time among the controllers 151 and 161. In thisexample, since there is more than one controller-side FMU 152 and 162,the co-simulation master 150 handles the time synchronization amongthem.

The FMI-ESI tool may be used to expose the input/output (I/O) interfacefrom the controller side into the FMU side, which necessitates thecontroller-side FMUs 152 and 162. Each controller-side FMU 152 and 162typically has one or more controllers under its supervision. In thisexample, controller-side FMU 152 handles controller 151, andcontroller-side FMU 162 handles controller 161. The FMI-ESI tool used toconfigure each controller-side FMU 152 and 162.

When executing the simulation at runtime, the FMI co-simulation master150 coordinates the data exchange and clocks among the FMUs 152, 162,and 155. The tag server within the FMI-ESI coordinates the clock anddata exchange among the controllers 151 and 161 under eachcontroller-side FMU 152 and 162. In other words, the FMI-ESI may be usedto configure the controller-side FMUs 152 and 162 to interoperate withthe simulation FMU 155 and other types of FMUs (not shown). Theco-simulation master 150 coordinates the data exchange and global timebetween the FMUs 152, 162, and 155, and the tag server portion of theFMI-ESI in this case grabs the local time of each controller-side FMU152 and 162 to facilitate synchronizing the controllers 151 and 161under their supervision.

FIG. 1B is a block diagram that illustrates computing system 100 thatmay be used to facilitate simulating machines used in industrialautomation. Computing system 100 includes industrial controller system110, application programming interface (API) 120, and simulation model130. Computing system 100 is representative of any computingenvironment, which could include several different systems and deviceslocated in geographically diverse areas and interconnected viacommunication networks in a distributed manner in some examples.

Industrial controller system 110 comprises, for example, an industrialcontroller, which could include automation controllers, programmablelogic controllers (PLCs), or any other controllers used in automationcontrol. Industrial controller system 110 could comprise one or morephysical and/or emulated controllers implemented in software—includingcombinations thereof. Simulation model 130 comprises definitions for avirtual representation of at least a portion of a machine used in anindustrial automation environment. Simulation model 130 is typicallycreated, at least in part, using a simulation application. In someimplementations, the simulation application employed may comply with theFMI standard, so that FMI may be used to wrap the simulation moduleinside of an FMU. For example, the simulation application could comprisea third-party simulation framework tool, such as MATLAB® Simulink™,although the simulation application could comprise any other suitablesimulation application or combination of applications in someimplementations. API 120 provides an interface that enablescommunication between industrial controller system 110 and simulationmodel 130, among other functionality. An operation of computing system100 will now be described with respect to FIG. 2.

FIG. 2 is a flow diagram that illustrates an operation 200 of computingsystem 100 in an exemplary implementation. The operation 200 shown inFIG. 2 may also be referred to as synchronization process 200 herein.The steps of operation 200 are indicated below parenthetically. Thefollowing discussion of synchronization process 200 will proceed withreference to computing system 100 of FIG. 1B in order to illustrate itsoperations, but note that the details provided in FIG. 1B are merelyexemplary and not intended to limit the scope of synchronization process200 to the specific implementation shown in FIG. 1B.

Synchronization process 200 may be employed to operate computing system100 to facilitate simulating machines used in industrial automation. Asshown in the operational flow of synchronization process 200, computingsystem 100 utilizes an application programming interface (API) 120 toapply timestamps to data exchanged between a simulation model created ina simulation application and an industrial controller system external tothe simulation model (201). In some implementations, the industrialcontroller system 110 could comprise one or more physical industrialcontroller devices, emulated industrial controllers implemented insoftware, or any other control system—including combinations thereof.The simulation model 130 may typically comprise definitions for avirtual representation of at least a portion of a machine used in anindustrial automation environment. For example, the simulation model 130could define the design and parameters of an entire robot, or coulddefine an individual component of the robot, such as an arm joint, drivemotor, articulation mechanism, or some other portion of the robot. Insome examples, the simulation model 130 could include information forrendering a three dimensional visualization of the machine, or at leasta portion thereof.

Among other functionality, API 120 may facilitate data exchange betweenthe simulation model 130 and the industrial controller system 110 in abidirectional manner. For example, the data transferred from theindustrial controller system 110 to the simulation model 130 couldcomprise control signals used to drive the simulation, and the datareceived by the industrial controller system 110 from the simulationmodel 130 could comprise feedback, operational status, and otherinformation associated with the execution of the simulation model 130.In some implementations, API 120 could be utilized to establish at leastone communication link between the industrial controller system 110 andthe simulation model 130 by linking ports associated with the industrialcontroller system 110 to the simulation model 130 to create an input andoutput interface between the industrial controller system 110 and thesimulation model 130. Data may then be exchanged over the communicationlink between the industrial controller system 110 and the simulationmodel 130 by utilizing the input and output interface to transfercontrol program parameters, control signals, and other informationbetween the industrial controller system 110 and the simulation model130. The simulation model 130 may then utilize the data received fromthe industrial controller system 110 to generate an animatedvisualization of a machine being simulated. For example, the data fromthe industrial controller system 110 could direct the simulation model130 to move and animate a three dimensional visualization of thesimulated machine in the same manner that the industrial controllersystem 110 could drive the physical machine itself.

In some implementations, API 120 may be utilized to apply timestamps toany of the data exchanged between the industrial controller system 110and the simulation model 130. For example, API 120 could be utilized toapply a first timestamp to data as soon as it is transferred by theindustrial controller system 110 for delivery to the simulation model130, and to apply a second timestamp immediately before providing thedata to the simulation model 130, and vice versa. Other techniques ofutilizing API 120 to apply timestamps to data exchanged between thesimulation model 130 and the industrial controller system 110 arecontemplated and within the scope of this disclosure.

The timestamps are then processed to synchronize the simulation model130 and the industrial controller system 110 (202). In some embodiments,the timestamps may be utilized to determine the timing of when toprovide the data to the simulation model 130 or the industrialcontroller system 110 to achieve synchronization. In at least oneimplementation, processing the timestamps to synchronize the simulationmodel 130 and the industrial controller system 110 could comprisecoordinating signal transmission intervals of the simulation model 130and the industrial controller system 110 using the timestamps.Coordinating the signal transmission intervals between the simulationmodel 130 and the industrial controller system 110 is necessary in someexamples because the signal transmission intervals could often comprisedifferent rates. In some implementations, processing the timestamps tosynchronize the simulation model 130 and the industrial controllersystem 110 could comprise providing a periodic clock pulse to thesimulation model 130 and the industrial controller system 110 to advancethe simulation model 130 and the industrial controller system 110 aheadone time step. Note that the time step size for the simulation model 130and the industrial controller system 110 could comprise differentvalues, but would both be advanced by the appropriate amount responsiveto the periodic clock pulse. Additionally, in implementations where theindustrial controller system 110 comprises multiple controllers, eachcontroller could have a different time step size, and each of thesecontrollers could be further synchronized at each clock pulse bydynamically calculating the deltas for use in compensating for thedifferences in time step size between the multiple controllers.

Advantageously, the API 120 may be utilized to apply timestamps to dataexchanged between the simulation model 130 and the industrial controllersystem 110. The timestamps may then be processed in order to facilitatesynchronization between the execution of the simulation model 130 andthe industrial controller system 110. In this manner, the simulationmodel 130 is able to receive and interpret control signals transmittedby the industrial controller system 110 at the appropriate timing toachieve smooth and harmonious operation of the simulation, therebyincreasing the value and utility of the simulation model 130 throughintegration and synchronization with the industrial controller system110.

Turning now to FIG. 3, FIG. 3 is a block diagram that illustrates anoverview 300 of implementing controllers with simulated industrialdevices. Overview 300 includes controller module 310, simulation module320, co-simulation assembly module 330, and resulting module 340.Controller module 310 may be any physical or emulated controllerconfigured to manage one or more devices in an industrial automationsystem. In some implementations, controller module 310 may be configuredto provide control instructions that direct physical and/or simulatedmachines, or their individual components, to move or perform some actionin three-dimensional space, such as controlling the motion of a robotarm. Simulation module 320 may be configured to generate a simulationmodel comprising simulation files that define various properties,parameters, and physical attributes of a real-world industrial device toensure that the simulated device looks and operates in the same manneras the physical device from which it is modeled.

Typically, the baseline controller is a physical hardware device inwhich a control program may be executed. A control program may then beloaded that is targeted to that specific controller hardware in order toretarget it to an emulation controller implemented in software. Thus,one workflow includes moving from physical to emulation control whichallows for improved modeling versatility. Once in an emulation model,the emulation controller may interact with the simulation model. Anotherworkflow considers a case in which the control program is fully designedin the emulation controller against the simulation. In this case, oncethe control program has been designed, it can be retargeted to thehardware controller. Notably, in both of the above transitions, theinput/output (I/O) interface is preserved between the physical machineand the physical controller or the simulated machine and the emulationcontroller.

In operation, a user, an engineer, or some other entity may generate asimulation within simulation module 320. Such a simulation may be usedto model various industrial equipment, including robotic, fabrication,assembly, and other types of equipment. In addition to generating thesimulation, a user may further wish to control the simulation using anindustrial controller from controller module 310. Controller module 310as used herein is intended to represent a real, physical controllerdevice or an emulated controller implemented in software that providescontrol instructions to the generated simulation. For example, if thesimulation was used to emulate a robotic arm, one or more controllerscould be used to manage and control the movement and articulation of thearm.

Once the controller and the simulation have been selected, thecontroller and simulation are then formatted using co-simulationassembly module 330. In some examples, co-simulation assembly module 330can be used to format the controller and the simulation using afunctional mock-up interface (FMI). FMI defines a standardized interfaceto be used in computer simulations to develop complex cyberphysicalsystems. These cyberphysical systems are represented in functionalmock-up units (FMUs) that provide the functions necessary to generatethe simulation. The functional mock-up units typically include anextensible markup language (XML) file comprising definitions of thevariables used by the FMUs, equations used by the model, which may bedefined as a set of functions, and other optional data, such asparameter tables, a user interface, and documentation which may beneeded by the model, among other things.

In the present example, the FMI further includes information necessaryto provide the control functions. As a result, necessary portions of thecontrol functions are implemented in functional mock-up units to makethe controls appear as simulation information within the FMI. Thecombination of the simulation functional mock-up units 344 and thecontrol functional mock-up units 345 are used to provide resultingmodule 340. Although illustrated using a functional mock-up interface,it should be understood that resulting module 340 could take the form ofany other similar standardized interface for simulation. An emulationsimulation interface environment is used to provide for this interfacewhich is unique to each specific control system vendor. Translators maybe provided throughout the emulation simulation interface fromindustrial control space to FMI space and vice versa.

In some examples, a user may control the simulation directly from thecontrol functional mock-up units. Thus, the control functional mock-upunits include all of the necessary functions to both receive a controlinstruction and execute that function. In other implementations, thecontrol functional mock-up units may contain only the portion ofinformation necessary to control the simulation. As a result, anexternal controller that receives input from the user may communicatewith the control functional mock-up units using an applicationprogramming interface (API), such as API 120 as shown in FIG. 1B.

Referring now to FIG. 4, FIG. 4 is a block diagram that illustrates anoperational scenario 400 involving a computing system in an exemplaryimplementation. The computing system executes emulation simulationinterface 410 and may execute some or all of the operations ofindustrial controller system 420 and simulation application 430. In someexamples, the computing system could be a single device or could bedistributed across many different systems and devices separated overdiverse geographic areas.

As shown in FIG. 4, the emulation simulation interface 410 includes aconfigurator module 411, a tag server 412, and a synchronizer 413. Inthis example, the industrial controller system 420 comprises a virtualcontroller emulator, such as RSLogix™ Emulate 5000 provided by RockwellAutomation, Inc. The simulation application 430 could comprise anythird-party simulation framework tool that complies with the FMIstandard, but the MATLAB® Simulink™ tool is used in this example. Thus,the simulation model 435 could comprise a .mdl file created in MATLAB®using library blocks for different systems.

The emulation simulation interface 410 is used to connect controllertags to the simulation model 435 in MATLAB®. To connect the virtualcontroller output signals to the simulation model 435, it is necessaryto establish an interface between the simulation model 435 and theindustrial controller system 420. To this end, the emulation simulationinterface 410 will set up an interface between input/output (I/O)signals of the controller 420 with the simulation model 435. Theinterface established by the emulation simulation interface 410 enablesconnectivity and data exchange in a bidirectional manner between thesimulation model 435 and the controller 420. In this example, theemulation simulation interface 410 uses a virtual controller emulatorsuch as RSLogix™ Emulate 5000 to encapsulate the control programs. Thecontroller emulator mimics the operation of a ControlLogix™ programmablelogic controller (PLC) but in software only. The virtual controller 420transfers data to the simulation using output tags and receives datafrom the simulation using input tags.

The configurator component 411 hosts the application-level informationfor connecting the virtual controller 420 with the simulation model 435.Tag server 412 coordinates the input and output tags for data exchange.In some implementations, tag server 412 provides distributedcommunication connectivity services for connecting the communicatingparts in the controller side of the spectrum. The co-simulation masterfrom FMI coordinates communication between the FMUs. Underneath the tagserver service, the controllers and their respective communications arecoordinated with simulations, which can become a very complex network ofcommunicating units.

The synchronizer 413 coordinates the clock progression between thecontroller 420 and the simulation model 435 to keep them synchronized.The clock synchronization is typically carried out in two phases. First,the co-simulation master coordinates global time among FMUs. Second, thetag server service 412 coordinates control level FMU time among thecontrollers. In situations where there is more than one control levelFMU, time synchronization among them may be handled by the co-simulationmaster. An example of how the execution of a controller and a simulationmay be synchronized at runtime will now be discussed with respect toFIG. 5.

FIG. 5 is a block diagram that illustrates an operational scenario 500for synchronizing a controller and a simulation in an exemplaryimplementation. Operational scenario 500 involves controller module 510,simulation module 530, and co-simulation master 540. Controller module510 includes API 520. In this example, controller module 510 comprises acontroller-side FMU and simulation module 530 comprises a simulationFMU.

In operation, API 520 of controller module 510 generally reads andwrites tags for data exchanged between the controller module 510 and thesimulation module 530, and functions to synchronize the timingassociated with this data exchange and execution of the simulation. Forexample, the signal transmission intervals of the controller module 510and the simulation model 530 may be exchanged at different time rates,and the co-simulation master 540 works in conjunction with API 520 tocompensate for these different rates to achieve synchronization.

In this example scenario, controller module 510 is transferring controldata to the simulation module 530. Co-simulation master 540 provides aninterface to connect the controller module 510 FMU and the simulationmodule 530 FMU. As controller module 510 transfers the control data tosimulation module 530, co-simulation master 540 utilizes API 520 toapply a first timestamp to the control data to mark the time in.Co-simulation master 540 then provides the control data to simulationmodule 530 and a second timestamp is applied to the data to mark thetime out. In this manner, co-simulation master 540 is aware of what timethe controller module 510 intended to provide the control data to thesimulation module 530 based on the first timestamp noting the time in,and what time the simulation module 530 actually receives the controldata based on the second timestamp noting the time out.

To ensure the controller module 510 and the simulation module 530 areoperating in a synchronized manner, co-simulation master 540 calculatestime offsets for the control data based on the timestamps to compensatefor delay and other timing anomalies. The co-simulation master 540 thenadvances the master clock one clock cycle and sends a clock pulse toboth the controller module 510 and the simulation module 530 to advanceeach module ahead one time step. Note that the time step size may not bethe same size for the simulation module 530 and the controller module510.

In some examples, the FMUs of both the simulation module 530 and thecontroller module 510 are configured to emit periodic pulses, such asevery twenty milliseconds, into the simulation and controller,respectively, to advance in time at the appropriate time step sizes,since as noted above, the time step sizes may not be the same size forthe simulation module 530 and the controller module 510. Also, inimplementations where the controller module 510 includes multiplecontrollers, each of the controllers in the controller module 510 couldbe operating at different time step sizes. An example of how multiplecontrollers that operate at different time step sizes could besynchronized will now be discussed in greater detail with respect toFIG. 6.

FIG. 6 is a controller synchronization chart 600 that illustrates anexemplary technique of synchronizing multiple controllers. The multiplecontrollers could comprise several separate physical controller devices,multiple independent emulated controllers implemented in software, orcombinations thereof. For example, multiple controllers could be used tocontrol several separate components of a single machine being simulated,such as various drive motors, articulation mechanisms, and other partsof the machine. In this example, the controllers are numbered C1, C2,and C3. The time step size in this example is ten milliseconds, as shownalong the horizontal x-axis of controller synchronization chart 600.

As shown in controller synchronization chart 600, after a firstiteration, controller C1 has advanced fifteen milliseconds, C2 hasadvanced ten milliseconds, and C3 has advanced five milliseconds. Thesedifferent intervals are then processed to dynamically calculate timeoffsets from the time step size of ten milliseconds in order tocompensate for the different signal transmission intervals of thecontrollers C1, C2, and C3. For controller C1, the time offset iscalculated to be a plus five millisecond delta from the time step size,since C1 advanced fifteen milliseconds but the time step size is onlyten milliseconds. The next time step for controller C1 is thencalculated by subtracting the delta from the time step size, so with atime step size of ten milliseconds minus a plus five millisecond delta,C1 should only advance five milliseconds on the next time step toachieve synchronization with the other controllers and the tenmillisecond time step size.

Controller C2 has a time step size of ten milliseconds, which matchesthe time step size of the simulation. Thus, no offset needs to becalculated and no compensation of the time step size of controller C2 isnecessary for synchronization. Controller C3 has a time step size ofonly five milliseconds, so the time offset is calculated to be anegative five millisecond delta from the time step size of tenmilliseconds. The next time step for controller C3 is then calculated bysubtracting the delta from the time step size, so with a time step sizeof ten milliseconds minus a negative five millisecond delta, C1 shouldadvance fifteen milliseconds on the next time step to achievesynchronization with the other controllers and the overall tenmillisecond time step size. As the simulation advances, the offsets foreach of the controllers C1, C2, and C3 are then continually recalculateddynamically at each time step to ensure synchronization persists. Inthis manner, the simulation model proceeds to learn the amplitude andfrequency of the sinusoidal time progression of each of the controllersC1, C2, and C3.

FIG. 7 is a block diagram that illustrates an operational scenario 700involving a computing system in an exemplary implementation. Operationalscenario 700 is capable of creating and operating a machine simulationin an industrial automation environment. To integrate design, control,simulation, and visualization, the following system and work flow may beused. According to an example, the system architecture may consistgenerally of five main parts: control program design 710, industrialcontroller system 720, simulation modeling 730, computer-aided design(CAD) solid modeling 740, and visualization 750. Various industry-basedtools and open source software may be used to implement these designgoals.

In an example, control programming design 710 may be carried out using acontrol programming tool, such as the Studio5000™ programming tool byRockwell Automation, Inc. Control program execution is handled byindustrial controller system 720, which could comprise an emulatedvirtual controller implemented in software, such as RSLogix™ Emulate5000 by Rockwell Automation, Inc. Simulation modeling 730 can beperformed by any simulation framework tool, such as the MATLAB®Simulink™ tool. Solid modeling 740 may be handled by any CAD software,such as Solidworks™ or the like. Finally, visualization 550 may beperformed by any suitable visualization tool, such as a Scalable VectorGraphics (SVG) tool, Virtual Reality Modeling Language (VRML) tool, andothers. Each of the above tools brings its own data structures andinformation formats into the design process. The challenge for theintegrated design and validation environment is to combine the pieces ofinformation into a common information exchange structure that can beused to harmonize the components into a rapid prototyping environment.

In FIG. 7, an example information flow of the integrated system isshown. The solid modeling phase 740 produces a three dimensionalrepresentation of the mechanical system to be controlled. The solidmodel may be converted into two information elements: a kinematicssimulation and a graphical assembly. The Solidworks™ tool providesplugins to generate both data files as MATLAB® simulation and VRMLexport files.

The Studio5000™ tool by Rockwell Automation is an industrial controlprogramming design tool 710 that is used to create control algorithmswritten in an International Electrotechnical Commission (IEC)61131-based programming language. The control program is deployed in thevirtual controller within industrial controller system 720.

The kinematics simulation is downloaded to the MATLAB® tool forsimulating the machine under specific load conditions. The simulationmodel 730 interacts with the controller 720 at runtime to stimulate thecontrolling algorithms with the responses of the machine that is putunder stress with dynamic loading and control profiles. Graphicalassemblies will be further processed to become a hierarchical datastructure of graphical description that can be animated in thevisualization tool 750. The visualization tool collects the real-timedata that is generated in the controller-to-simulation interaction.

Different techniques may be used to connect each phase of thisinformation flow. In one implementation, control program parameters aretransferred between the simulation model 730 and the controller 720using an I/O interface. MATLAB® provides a SimMechanicsLinks plugin forCAD software Solidworks™ to transfer the CAD model produced in the solidmodeling phase 740 into the simulation model 730. The simulation model730 contains mass and inertial properties of each of the component partsof a machine described in the CAD drawings. This information isessential to generate accurate animation of the mechanical system.

Kinematics and dynamical information of the simulation model 530 can beused to generate realistic model conditions since the actual physicalproperties of the model are included in the simulation calculations. Asdiscussed above, visualization 550 may be performed by any suitablevisualization tool, such as a Scalable Vector Graphics (SVG) tool,Virtual Reality Modeling Language (VRML) tool, or any other simulationmodeling tool. In at least one implementation, a high quality andrealistic animation can be produced in any VRML-compatible tool usingthe exported VRML models. VRML provides an open source,platform-independent graphical language to create and view threedimensional models. VRML is a text-based language so it can be easilyedited using any text editor. To bring the VRML tool into this workflow,it is necessary to attach an API to it so it can communicate with theother parts of the system. Of course, other tools besides VRML may beutilized for this purpose and are within the scope of this disclosure.

Based on this work flow, an application can be created using thesedifferent systems under one platform. Robots are widely used inindustrial automation applications and their control algorithms aredeveloped by system engineers. In an example, a six-axis articulatedrobot model may be used. A desired motion profile for the robot's endeffector position is established in the controlling program 710 usingcommand position profiles.

The command positions are points of desired motion trajectory for theend effector. To achieve a desired position of the end effector,different parts (links) of the robot must be placed in a position by thedriving motors at the link joints. These motors are driven by torquesignals that are to be calculated by the controlling drivers. However,the controlling torque depends on knowledge of the system response tothe torque and the load at the end effector. In the classical designapproach, these pieces of information are known by trial and error or byexperienced designers. The intent here is to capture the informationflow for automating the process of generating the feedback informationfor the drivers and controllers. Based on the drivers' torque signal,each joint will move and the end effector will move in the space to atarget location. Current position is the feedback to the drivers andcontrollers for close loop control.

A work flow, validation framework, and process to enable a virtualdesign engineering environment have been presented. The environmentenables interoperability of solid model design, controllers, simulation,and visualization tools into an integrated development environment.Results showed that the selected work flow and information exchangecould be assembled in an automated system. The deployment of the virtualdesign engineering environment permitted observing in real-time theeffect of the controlling algorithm on the machine prototype which wassimulated and controlled by motion instructions. This disclosure enablesearly validation of controlling logic for complex industrial automationprojects and manufacturing plants. The benefits include the reduction ofengineering cost, time, and resources during the design and prototypingof industrial automation machinery. In addition, the virtual designengineering environment opens new opportunities to train engineers andoperators in controlling machines, without the need for the physicalpresence of the actual machine.

It must be noted that the invention can be used in two main phases:design phase runtime and commissioned phase runtime. During design phaseruntime, the industrial control device can be real or emulated. Eitherencapsulation is connected to the simulation. In commissioned phaseruntime, the industrial control device and the simulation execute inparallel with a real controller. Additionally, another benefit of thesystem is to aid system engineers to create optimized industrial controlprograms. For example, the Studio5000™ tool by Rockwell Automationallows for online editing of the control program, and the design may beincrementally improved in virtual design.

FIG. 8 is a block diagram that illustrates computing system 800 in anexemplary implementation. Computing system 800 provides an example ofcomputing system 100 or any system that may be used to facilitatesimulating machines used in industrial automation, although othersystems capable of performing the techniques disclosed herein could usealternative configurations, including computing system 100. Computingsystem 800 is representative of a computing system that may be employedin any computing apparatus, system, or device, or collections thereof.For example, computing system 800 may be employed in server computers,cloud computing platforms, data centers, any physical or virtualcomputing machine, and any variation or combination thereof. Inaddition, computing system 800 may be employed in desktop computers,laptop computers, tablets, smartphones, or the like.

Computing system 800 includes processing system 801, storage system 803,software 805, communication interface 807, and user interface 809.Processing system 801 is operatively coupled with storage system 803,communication interface 807, and user interface 809. Processing system801 loads and executes software 805 from storage system 803. Software805 includes application 806 which itself includes synchronizationprocess 200. Synchronization process 200 may optionally be implementedseparately from application 806. When executed by computing system 800in general, and processing system 801 in particular, software 805directs computing system 800 to operate as described herein forsynchronization process 200 or variations thereof. Computing system 800may optionally include additional devices, features, or functionalitynot discussed here for purposes of brevity.

Computing system 800 may be representative of any computing apparatus,system, or systems on which application 806 and synchronization process200 or variations thereof may be suitably implemented. Examples ofcomputing system 800 include mobile computing devices, such as cellphones, tablet computers, laptop computers, notebook computers, andgaming devices, as well as any other type of mobile computing devicesand any combination or variation thereof. Note that the features andfunctionality of computing system 800 may apply as well to desktopcomputers, server computers, and virtual machines, as well as any othertype of computing system, variation, or combination thereof.

Referring still to FIG. 8, processing system 801 may comprise amicroprocessor and other circuitry that retrieves and executes software805 from storage system 803. Processing system 801 may be implementedwithin a single processing device but may also be distributed acrossmultiple processing devices or sub-systems that cooperate in executingprogram instructions. Examples of processing system 801 include generalpurpose central processing units, application specific processors, andlogic devices, as well as any other type of processing device,combinations, or variations thereof.

Storage system 803 may comprise any non-transitory computer-readablemedia or storage media readable by processing system 801 and capable ofstoring software 805, such as a disk drive, flash drive, data storagecircuitry, or some other hardware memory apparatus. In some examples, acomputer apparatus could comprise storage system 803 and operatingsoftware 805. Storage system 803 may include volatile and nonvolatile,removable and non-removable media implemented in any method ortechnology for storage of information, such as computer readableinstructions, data structures, program modules, or other data. Storagesystem 803 may be implemented as a single storage device but may also beimplemented across multiple storage devices or sub-systems co-located ordistributed relative to each other—including devices in differentgeographic areas. Storage system 803 may also be embedded in varioustypes of equipment. Storage system 803 may comprise additional elements,such as a controller, capable of communicating with processing system801. Examples of storage media include random access memory, read onlymemory, magnetic disks, optical disks, flash memory, virtual memory andnon-virtual memory, magnetic cassettes, magnetic tape, magnetic diskstorage or other magnetic storage devices, or any other medium which canbe used to store the desired information and that may be accessed by aninstruction execution system, as well as any combination or variationthereof, or any other type of storage media. In no case is the storagemedia a propagated signal.

In operation, processing system 801 loads and executes portions ofsoftware 805, such as synchronization process 200, in order to operateas described herein. In particular, software 805 may be implemented inprogram instructions and among other functions may, when executed bycomputing system 800 in general or processing system 801 in particular,direct computing system 800 or processing system 801 to utilize anapplication programming interface (API) to apply timestamps to dataexchanged between a simulation model created in a simulation applicationand an industrial controller system external to the simulation model,and process the timestamps to synchronize the simulation model and theindustrial controller system. Software 805 may include additionalprocesses, programs, or components, such as operating system software orother application software. Examples of operating systems includeWindows®, iOS®, and Android®, as well as any other suitable operatingsystem. Software 805 may also comprise firmware or some other form ofmachine-readable processing instructions executable by processing system801.

In general, software 805 may, when loaded into processing system 801 andexecuted, transform computing system 800 overall from a general-purposecomputing system into a special-purpose computing system customized tofacilitate simulating machines used in industrial automation asdescribed herein for each implementation. Software 805 may alsotransform the physical structure of storage system 803. The specifictransformation of the physical structure may depend on various factorsin different implementations of this description. Examples of suchfactors may include, but are not limited to, the technology used toimplement the storage media of storage system 803, whether thecomputer-storage media are characterized as primary or secondarystorage, and the like. For example, if the computer-storage media areimplemented as semiconductor-based memory, software 805 may transformthe physical state of the semiconductor memory when the software isencoded therein. For example, software 805 may transform the state oftransistors, capacitors, or other discrete circuit elements constitutingthe semiconductor memory. A similar transformation may occur withrespect to magnetic or optical media. Other transformations of physicalmedia are possible without departing from the scope of the presentdescription, with the foregoing examples provided only to facilitatethis discussion.

Communication interface 807 may include communication connections anddevices that allow for communication between computing system 800 andother computing systems (not shown) or services, over a communicationnetwork or collection of networks. Examples of connections and devicesthat together allow for inter-system communication may include networkinterface cards, antennas, power amplifiers, RF circuitry, transceivers,and other communication circuitry. The aforementioned network,connections, and devices are well known and need not be discussed atlength here.

User interface 809 may include a voice input device, a touch inputdevice for receiving a gesture from a user, a motion input device fordetecting non-touch gestures and other motions by a user, and othercomparable input devices and associated processing elements capable ofreceiving user input from a user. Output devices such as a displaysystem, speakers, haptic devices, and other types of output devices mayalso be included in user interface 809. The aforementioned user inputdevices are well known in the art and need not be discussed at lengthhere. User interface 809 may also include associated user interfacesoftware executable by processing system 801 in support of the varioususer input and output devices discussed above. Separately or inconjunction with each other and other hardware and software elements,the user interface software and devices may provide a graphical userinterface, a natural user interface, or any other kind of userinterface.

The functional block diagrams, operational sequences, and flow diagramsprovided in the Figures are representative of exemplary architectures,environments, and methodologies for performing novel aspects of thedisclosure. While, for purposes of simplicity of explanation, methodsincluded herein may be in the form of a functional diagram, operationalsequence, or flow diagram, and may be described as a series of acts, itis to be understood and appreciated that the methods are not limited bythe order of acts, as some acts may, in accordance therewith, occur in adifferent order and/or concurrently with other acts from that shown anddescribed herein. For example, those skilled in the art will understandand appreciate that a method could alternatively be represented as aseries of interrelated states or events, such as in a state diagram.Moreover, not all acts illustrated in a methodology may be required fora novel implementation.

The above description and associated drawings teach the best mode of theinvention. The following claims specify the scope of the invention. Someaspects of the best mode may not fall within the scope of the inventionas specified by the claims. Also, while the preceding discussiondescribes embodiments employed specifically in conjunction with themonitoring and analysis of industrial processes, other applications,such as the mathematical modeling or monitoring of any man-made ornaturally-existing system, may benefit from use of the conceptsdiscussed above. Further, those skilled in the art will appreciate thatthe features described above can be combined in various ways to formmultiple variations of the invention. As a result, the invention is notlimited to the specific embodiments described above, but only by thefollowing claims and their equivalents.

What is claimed is:
 1. One or more computer-readable storage mediahaving program instructions stored thereon to facilitate simulatingmachines used in industrial automation, wherein the programinstructions, when executed by a computing system, direct the computingsystem to at least: utilize an application programming interface (API)to apply timestamps to data exchanged between a simulation model createdin a simulation application and an industrial controller system externalto the simulation model; and process the timestamps to synchronize thesimulation model and the industrial controller system.
 2. The one ormore computer-readable storage media of claim 1 wherein, to process thetimestamps to synchronize the simulation model and the industrialcontroller system, the program instructions direct the computing systemto provide a periodic clock pulse to the simulation model and theindustrial controller system to advance the simulation model and theindustrial controller system ahead one time step.
 3. The one or morecomputer-readable storage media of claim 1 wherein, to process thetimestamps to synchronize the simulation model and the industrialcontroller system, the program instructions direct the computing systemto coordinate signal transmission intervals of the simulation model andthe industrial controller system using the time stamps.
 4. The one ormore computer-readable storage media of claim 1 wherein the dataexchanged between the simulation model and the industrial controllersystem comprises control signals transferred from the industrialcontroller system to the simulation model.
 5. The one or morecomputer-readable storage media of claim 1 wherein the simulation modelcomprises definitions for a virtual representation of at least a portionof a machine used in an industrial automation environment.
 6. The one ormore computer-readable storage media of claim 5 wherein the simulationmodel utilizes the data to generate an animated visualization of themachine.
 7. The one or more computer-readable storage media of claim 1wherein the industrial controller system comprises an emulatedindustrial controller implemented in software.
 8. A method of operatinga computing system to facilitate simulating machines used in industrialautomation, the method comprising: utilizing an application programminginterface (API) to apply timestamps to data exchanged between asimulation model created in a simulation application and an industrialcontroller system external to the simulation model; and processing thetimestamps to synchronize the simulation model and the industrialcontroller system.
 9. The method of claim 8 wherein processing thetimestamps to synchronize the simulation model and the industrialcontroller system comprises providing a periodic clock pulse to thesimulation model and the industrial controller system to advance thesimulation model and the industrial controller system ahead one timestep.
 10. The method of claim 8 wherein processing the timestamps tosynchronize the simulation model and the industrial controller systemcomprises coordinating signal transmission intervals of the simulationmodel and the industrial controller system using the timestamps.
 11. Themethod of claim 8 wherein the data exchanged between the simulationmodel and the industrial controller system comprises control signalstransferred from the industrial controller system to the simulationmodel.
 12. The method of claim 8 wherein the simulation model comprisesdefinitions for a virtual representation of at least a portion of amachine used in an industrial automation environment.
 13. The method ofclaim 12 wherein the simulation model utilizes the data to generate ananimated visualization of the machine.
 14. The method of claim 8 whereinthe industrial controller system comprises an emulated industrialcontroller implemented in software.
 15. A computer apparatus to operatea computing system to facilitate simulating machines used in industrialautomation, the apparatus comprising: software instructions configured,when executed by the computing system, to direct the computing system toutilize an application programming interface (API) to apply timestampsto data exchanged between a simulation model created in a simulationapplication and an industrial controller system outside of thesimulation model, and process the timestamps to synchronize thesimulation model and the industrial controller system, wherein thesimulation model comprises definitions for a virtual representation ofat least a portion of a machine used in an industrial automationenvironment and wherein the simulation model utilizes the data togenerate an animated visualization of the machine; and at least onenon-transitory computer-readable storage medium storing the softwareinstructions.
 16. The computer apparatus of claim 15 wherein thesoftware instructions configured to direct the computing system toprocess the timestamps to synchronize the simulation model and theindustrial controller system comprises the software instructionsconfigured to direct the computing system to provide a periodic clockpulse to the simulation model and the industrial controller system toadvance the simulation model and the industrial controller system aheadone time step.
 17. The computer apparatus of claim 15 wherein thesoftware instructions configured to direct the computing system toprocess the timestamps to synchronize the simulation model and theindustrial controller system comprises the software instructionsconfigured to direct the computing system to coordinate signaltransmission intervals of the simulation model and the industrialcontroller system using the timestamps.
 18. The computer apparatus ofclaim 17 wherein the signal transmission intervals of the simulationmodel and the industrial controller system are different rates.
 19. Thecomputer apparatus of claim 15 wherein the data exchanged between thesimulation model and the industrial controller system comprises controlsignals transferred from the industrial controller system to thesimulation model.
 20. The computer apparatus of claim 15 wherein theindustrial controller system comprises an emulated industrial controllerimplemented in software.